package ui;

import java.awt.Button;
import ui.listeners.CheckerBoardQuitButtonClickListener;

/**
 * This button will close the program down when clicked.
 * 
 * @author Team Titanium
 */
public class CheckerBoardQuitButton extends Button {

	/**
	 * Generated serial ID value used if (and when) this object is serialized.
	 */
	private static final long serialVersionUID = 4351827352044026977L;

	/**
	 * Builds a button with no label that, when clicked, will close the game
	 * down.
	 */
	public CheckerBoardQuitButton() {
		this("");
	}

	/**
	 * Builds a button with the provided label that, when clicked, will close
	 * the game down.
	 * 
	 * @param label
	 *            A label to add to this button. The label will show when this
	 *            button is added to a Window object.
	 */
	public CheckerBoardQuitButton(String label) {
		super(label);
		this.addActionListener(new CheckerBoardQuitButtonClickListener());
	}
}
